Code Instruction Selection Based on SSA-Graphs

نویسندگان

  • Erik Eckstein
  • Oliver König
  • Bernhard Scholz
چکیده

Instruction selection for embedded processors is a challenging problem. Embedded system architectures feature highly irregular instruction sets and complex data paths. Traditional code generation techniques have difficulties to fully utilize the features of such architectures and typically result in inefficient code. In this paper we describe an instruction selection technique that uses static single assignment graphs (SSA-graphs) as underlying data structure for selection. Patterns defined as graph grammar guide the instruction selection to find (nearly) optimal results. We present an approach which maps the pattern matching problem to a partitioned boolean quadratic optimization problem (PBQP). A linear PBQP solver computes optimal solutions for almost all nodes of a SSA-graph. We have implemented our approach in a production DSP compiler. Our experiments show that our approach achieves significant better results compared to classical tree matching.

برای دانلود رایگان متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

منابع مشابه

Near-Optimal Instruction Selection on DAGs

Instruction selection is a key component of code generation. High quality instruction selection is of particular importance in the embedded space where complex instruction sets are common and code size is a prime concern. Although instruction selection on tree expressions is a well understood and easily solved problem, instruction selection on directed acyclic graphs is NP-complete. In this pap...

متن کامل

Exploiting Symmetries for Optimal Integrated Code Generation

High quality code generation for irregular architectures, such as Digital Signal Processors, is a complex task, as it requires a fully integrated approach that simultaneously deals with the most important tasks of instruction selection, register allocation and instruction scheduling. We show how a fully integrated approach for optimal code generation based on dynamic programming can benefit fro...

متن کامل

Integer Linear Programming versus Dynamic Programming for Optimal Integrated VLIW Code Generation

To our knowledge there is only one Integer Linear Program ming ILP formulation in the literature that fully integrates all steps of code generation i e instruction selection register allocation and in struction scheduling on the basic block level We give in this paper an improved version of this ILP formulation that also covers VLIW proces sors Moreover our ILP formulation does no longer requir...

متن کامل

Translating Out of Predicated Static Single Assignment Form

Static Single Assignment (SSA) form is an intermediate representation that allows a compiler to perform advanced optimizations to extract parallelism. Predication is an architectural feature to maximize instruction level parallelism. If a compiler uses a predicated SSA form that is a combination of an SSA form and predication as an intermediate representation, it can perform advance optimizatio...

متن کامل

SSA Elimination after Register Allocation

The SSA-form uses a notational abstractions called φ-functions. These instructions have no analogous in actual machine instruction sets, and they must be replaced by ordinary instructions at some point of the compilation path. This process is called SSA elimination. Compilers usually performs SSA elimination before register allocation. But the order could as well be the opposite: our puzzle bas...

متن کامل

ذخیره در منابع من


  با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید

عنوان ژورنال:

دوره   شماره 

صفحات  -

تاریخ انتشار 2003